﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel.DataAnnotations;
using DataAnnotationsExtensions;

namespace WebUI.Models
{
    public class SignUpViewModel : BaseViewModelWithoutLogOnPartial
    {
        [Required]
        [UserName]
        [NoHtml]
        [Display(Name = "User name")]
        [StringLength(20, ErrorMessage = "The User name field has maximum 20 characters")]
        public string UserName { get; set; }

        [Required]
        [Email]
        [Display(Name = "Email")]
        [StringLength(48, ErrorMessage = "The Email field has maximum 48 characters")]
        public string Email { get; set; }

        [Required]
        [StringLength(32, MinimumLength = 6, ErrorMessage = "The Password field has minimum 6 characters and maxinum 32 characters")]
        [DataType(DataType.Password)]
        [Display(Name = "Password")]
        public string Password { get; set; }

        [Required]
        [NoHtml]
        [Display(Name = "First name")]
        [StringLength(20, ErrorMessage = "The First name field has maximum 20 characters")]
        public string FirstName { get; set; }

        [Required]
        [NoHtml]
        [Display(Name = "Last name")]
        [StringLength(20, ErrorMessage = "The Last name field has maximum 20 characters")]
        public string LastName { get; set; }

        [Required]
        [NoHtml]
        [Display(Name = "Title")]
        [StringLength(30, ErrorMessage = "The Title field has maximum 30 characters")]
        public string Title { get; set; }

        [Required]
        [NoHtml]
        [Display(Name = "Location")]
        [StringLength(30, ErrorMessage = "The Location field has maximum 30 characters")]
        public string Location { get; set; }
    }
}